package com.spc.car.data.service.sys;

import com.baomidou.mybatisplus.extension.service.IService;
import com.spc.car.data.entity.sys.SysAttachment;

import javax.validation.constraints.NotNull;
import java.util.List;

/**
 * <p>
 * 系统附件表 服务类
 * </p>
 *
 * @author 
 * @since 2020-03-17
 */
public interface SysAttachmentService extends IService<SysAttachment> {
    /**
     * 保存附件
     * @param attachment
     */
    void saveAttach(SysAttachment attachment);

    /**
     * 批量保存
     * @param attachments
     */
    void saveAttachBatch(List<SysAttachment> attachments);

    /**
     * 获取附件信息(根据ID)
     * @param attachId
     * @return
     */
    SysAttachment getAttachById(@NotNull Long attachId);


    /**
     * 根据附件ID移除附件
     * 注释：不作硬删除
     * @param attachId
     */
    void removeAttache(@NotNull Long attachId);
}
